package com.zmsoft.persistent.sfg.Sfg662020GameFarm;

import java.util.ArrayList;
import java.util.HashMap;

import org.cnsoft.framework.apidoc.MyApiDocSupport;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * 农场升级配置信息接口
 */
@CrossOrigin
@RestController
@RequestMapping(value = "/doc/1.0/base/sfg662020gamefarm", method = { RequestMethod.GET })
public class Sfg662020GameFarmApiDoc extends MyApiDocSupport {

	// 获得API地址
	public String loadApiDocName() throws Exception {
		return "农场升级配置信息;/doc/1.0/base/sfg662020gamefarm/all";
	}

	// API文档描述
	@RequestMapping(value = "/all", method = RequestMethod.GET)
	public HashMap<String, Object> loadApiDocValue() throws Exception {
		HashMap<String, Object> all = new HashMap<String, Object>();
		// 输出基本信息
		all.put("name", "农场升级配置信息");
		all.put("baseurl", "/api/1.0/base/sfg662020gamefarm");
		// 输出API列表
		{
			ArrayList<Object> list = new ArrayList<Object>();
			list.add("/list");
			list.add("/info");
			list.add("/append");
			list.add("/modify");
			list.add("/discard");
			all.put("apilist", list);
		}
		// 输出字段信息
		{
			ArrayList<Object> list = new ArrayList<Object>();
			HashMap<String, Object> item;
			{
				item = new HashMap<String, Object>();
				item.put("enname", "gameType");
				item.put("cnname", "游戏分类(1农场2牧场3鱼塘4工坊)");
				item.put("datatype", "String");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "gameName");
				item.put("cnname", "游戏名称");
				item.put("datatype", "String");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "nextFarmLevel");
				item.put("cnname", "目标等级");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needFarmExp");
				item.put("cnname", "所需经验");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needMoney");
				item.put("cnname", "所需金钱");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropId1");
				item.put("cnname", "所需道具1");
				item.put("datatype", "String");
				item.put("memo", "土地卡");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropName1");
				item.put("cnname", "所需道具名称1");
				item.put("datatype", "String");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropNum1");
				item.put("cnname", "所需道具数量1");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropId2");
				item.put("cnname", "所需道具2");
				item.put("datatype", "String");
				item.put("memo", "经验值");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropName2");
				item.put("cnname", "所需道具名称2");
				item.put("datatype", "String");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropNum2");
				item.put("cnname", "所需道具数量2");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropId3");
				item.put("cnname", "所需道具3");
				item.put("datatype", "String");
				item.put("memo", "好友数量");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropName3");
				item.put("cnname", "所需道具名称3");
				item.put("datatype", "String");
				item.put("memo", "");

				list.add(item);
			}
			{
				item = new HashMap<String, Object>();
				item.put("enname", "needPropNum3");
				item.put("cnname", "所需道具数量3");
				item.put("datatype", "Long");
				item.put("memo", "");

				list.add(item);
			}
			all.put("itemlist", list);
		}

		return all;
	}

}
